<template>
  <div>
    <div id="allmap"></div>
  </div>
</template>

<script>
import { defineComponent, nextTick, onMounted } from "vue";
export default defineComponent({
  setup() {
    onMounted(() => {
      nextTick(() => {
        initMap();
      });
    });
    const initMap = () => {
      let Bmap = window.BMap;
      let map = new Bmap.Map("allmap");
      map.centerAndZoom(
        new Bmap.Point(104.04263635868074, 30.556100647961866),
        11
      );
    };
    return {};
  },
});
</script>
<style  scoped>
#allmap {
  width: 100%;
  height: 450px;
}
</style>
